package Demo;

import java.io.FileNotFoundException;
import java.io.FileReader;
import java.io.IOException;
import java.io.Reader;

public class Demo011 {
    public static void main(String[] args) throws FileNotFoundException {
        try (Reader reader = new FileReader("./文本txt")) {
            while (true) {
                int c = reader.read();
                if (c == -1) {
                    break;
                }
                System.out.print((char) c);
            }
        } catch (IOException e) {
            e.printStackTrace();
        }
    }
}
